export default [
  {
    path: '/user', layout: false, routes: [
      {path: '/user/login', component: './User/Login'},
      { path: '/user/register', component: './User/Register' }
    ]
  },
  {
    path: '/welcome', 
    icon: 'smile', 
    component: './Welcome',
    access: 'isLogin', // 所有登录用户都可以访问
    menu: {
      name: '欢迎页面',
    },
  },
  {
    path: '/admin',
    name: '管理页',
    icon: 'crown',
    access: 'canAdmin', // 只有管理员可以访问
    component: './Admin',
    routes: [
      {path: '/admin/user-manage', name: '用户管理', component: './Admin/UserManage',icon: 'table'}
    ],
  },
  {
    icon: 'table', 
    path: '/list', 
    component: './TableList',
    menu: {
      name: '表格列表',
    },
  },
  {path: '/', redirect: '/welcome'},
  {path: '*', layout: false, component: './404'},
];
